package com.tanhua.model.vo;

import com.tanhua.model.domain.SoulOptionsContent;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.beans.BeanUtils;

import java.io.Serializable;

/**
 * @Description：test
 * @Create by： 张会豪
 * @Date：2021/11/8 0:04
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class SoulOptionsContentVo implements Serializable {

    String id;//String类型
    private String option;//选项内容

    public static SoulOptionsContentVo init(SoulOptionsContent soulOptionsContent) {
        SoulOptionsContentVo vo = new SoulOptionsContentVo();
        //copy用户属性  option
        BeanUtils.copyProperties(soulOptionsContent,vo);
        //设置id属性值 string
        vo.setId(soulOptionsContent.getId().toString());
        return vo;
    }
}
